public class Work8 {
    public static void main(String[] args) {
        int[] array = {2, 6, 4, 1};
        int count = 1;
        int tmp = 0;
        boolean flag = false;
        for (int i = 0; i < array.length; i++) {
            if (count == 3) {
                flag = true;
                break;
            }
            if (array[i] % 2 != 0) {
                tmp = i;
                count++;
            } else {
                i = tmp + 1;
                tmp++;
            }
        }
        System.out.println(flag);
    }
}
